import http from '@/utils/http'

const baseUrl = '/table-sample-class'

export interface TableSampleClassQuery {
    id?: number,
    sampleClassName?: string,
    pageNum: number,
    pageSize: number,
    status?: number
}

export interface TableSampleDto {
    id?: number
    sampleClassName: string
    updateBy: string
    status: number
}

export const listSampleType = (params: TableSampleClassQuery) => {
    return http.post(`${baseUrl}/list`, params)
}

export const addSampleType = (data: TableSampleDto) => {
    return http.post(baseUrl, data)
}

export const updateSampleType = (data: TableSampleDto) => {
    return http.put(baseUrl, data)
}

export const deleteSampleType = (id: number) => {
    return http.del(`${baseUrl}/${id}`)
}
